<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
    <%@ page import="java.util.ArrayList"%>
    <%@ page import="com.ipartek.formacion.bean.Alumno" %>
<!-- Importamos los tags de JSTL -->
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link rel="stylesheet" type="text/css" href="css/style.css"/>
<link rel="stylesheet" type="text/css" href="css/tables.css"/>
<title>Ranking de Alumnos</title>
</head>
<body>
<center>
<%
ArrayList<Alumno> listaAlumnos = (ArrayList<Alumno>) request.getAttribute("tablaAlumnos");

out.println("<h3>Ranking Alumnos</h3>");
out.println("<table id='tabla' border='1'><thead><tr><th>Nombre</th><th>1er Apellido</th><th>2do Apellido</th></tr></thead><tbody>");
for (int i=0; i < listaAlumnos.size(); i++){
	out.println("<tr>");
	out.println("<td>"+listaAlumnos.get(i).getNombre()+"</td>");
	out.println("<td>"+listaAlumnos.get(i).getApellido1()+"</td>");
	out.println("<td>"+listaAlumnos.get(i).getApellido2()+"</td>");
	out.println("</tr>");
	
}
out.println("</tbody></table>");
%>
</center>
</body>
</html>